package com.ruoyi.goods.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.annotation.Excel;
import com.ruoyi.common.core.web.domain.BaseEntity;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * #销售单管理对象 bm_inorderlist
 * 
 * @author ruoyi
 * @date 2023-08-03
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class BmInorderlist extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 订单编号 */
    @Excel(name = "订单编号")
    private String orderCode;

    /** 店铺id */
    @Excel(name = "店铺id")
    private Long sellerId;

    /** 配送费 */
    @Excel(name = "配送费")
    private Double deliveryFee;

    /** 订单金额 */
    @Excel(name = "订单金额")
    private BigDecimal amount;

    /** 支付方式 */
    @Excel(name = "支付方式")
    private Long payType;

    /** 订单步骤 */
    @Excel(name = "订单步骤")
    private Long orderStep;

    /** 配送地址id */
    @Excel(name = "配送地址id")
    private String deliveryAddressId;

    /** 支付时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "支付时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date payTime;

    /** 订单状态 */
    @Excel(name = "订单状态")
    private Long orderState;

    /** 订单配送步骤记录 */
    @Excel(name = "订单配送步骤记录")
    private String orderStepRecord;

    /** 仓库管理人员id */
    @Excel(name = "仓库管理人员id")
    private Long warehouserId;

    /** 物流人员id */
    @Excel(name = "物流人员id")
    private Long logisticsId;

    /** 订单备注 */
    @Excel(name = "订单备注")
    private String mark;
    private String warehouseCode;
    @Excel(name = "地址")
    private String address;
    private List<BmInordergoodslist> bmInordergoodslistList;
    private List<BmPreferential> bmPreferentialList;

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("orderCode", getOrderCode())
            .append("sellerId", getSellerId())
            .append("deliveryFee", getDeliveryFee())
            .append("amount", getAmount())
            .append("payType", getPayType())
            .append("orderStep", getOrderStep())
            .append("deliveryAddressId", getDeliveryAddressId())
            .append("createTime", getCreateTime())
            .append("payTime", getPayTime())
            .append("orderState", getOrderState())
            .append("orderStepRecord", getOrderStepRecord())
            .append("warehouserId", getWarehouserId())
            .append("logisticsId", getLogisticsId())
            .append("mark", getMark())
            .append("warehouseCode", getWarehouseCode())
            .append("address", getAddress())
            .append("bmInordergoodslistList", getBmInordergoodslistList())
            .append("bmPreferentialList", getBmPreferentialList())
            .toString();
    }
}
